package com.ssm.model;
//用户关注关系表
public class Concern {

	private Integer id;
	//关注者id
	private Integer concern_id;
	//被关注者id
	private Integer concerned_id;

	public Integer getId() {
		return id;
	}

	public void setId(Integer id) {
		this.id = id;
	}

	public Integer getConcern_id() {
		return concern_id;
	}

	public void setConcern_id(Integer concernId) {
		concern_id = concernId;
	}

	public Integer getConcerned_id() {
		return concerned_id;
	}

	public void setConcerned_id(Integer concernedId) {
		concerned_id = concernedId;
	}

	@Override
	public int hashCode() {
		final int prime = 31;
		int result = 1;
		result = prime * result
				+ ((concern_id == null) ? 0 : concern_id.hashCode());
		result = prime * result
				+ ((concerned_id == null) ? 0 : concerned_id.hashCode());
		result = prime * result + ((id == null) ? 0 : id.hashCode());
		return result;
	}

	@Override
	public boolean equals(Object obj) {
		if (this == obj)
			return true;
		if (obj == null)
			return false;
		if (getClass() != obj.getClass())
			return false;
		Concern other = (Concern) obj;
		if (concern_id == null) {
			if (other.concern_id != null)
				return false;
		} else if (!concern_id.equals(other.concern_id))
			return false;
		if (concerned_id == null) {
			if (other.concerned_id != null)
				return false;
		} else if (!concerned_id.equals(other.concerned_id))
			return false;
		if (id == null) {
			if (other.id != null)
				return false;
		} else if (!id.equals(other.id))
			return false;
		return true;
	}

	@Override
	public String toString() {
		return "Concern [concern_id=" + concern_id + ", concerned_id="
				+ concerned_id + ", id=" + id + "]";
	}

}
